Window configuration, balancing and fit-to-buffer rewrites.
authormartin rudalics <rudalics@gmx.at>
Sat, 11 Jun 2011 14:06:16 +0000 (16:06 +0200)
committermartin rudalics <rudalics@gmx.at>
Sat, 11 Jun 2011 14:06:16 +0000 (16:06 +0200)
commit253d42fe4c0878cf4e649e684e43a5e393848011
treed5ad31a0f1418c6484cfc356638f7bf6d840b4c9
parentbd4ba5d6d6b3eb58292d02444cd4b86eb0d721ad
Window configuration, balancing and fit-to-buffer rewrites.

* window.c (delete_deletable_window): Re-add.
(Fset_window_configuration): Rewrite to handle dead buffers and
consequently deletable windows.
(window_tree, Fwindow_tree): Remove.  Supply functionality in
window.el.
(compare_window_configurations): Simplify code.

* window.el (window-tree-1, window-tree): New functions, moving
the latter to window.el.
(bw-get-tree, bw-get-tree-1, bw-find-tree-sub)
(bw-find-tree-sub-1, bw-l, bw-t, bw-r, bw-b, bw-dir, bw-eqdir)
(bw-refresh-edges): Remove.
(balance-windows-1, balance-windows-2): New functions.
(balance-windows): Rewrite in terms of window tree functions,
balance-windows-1 and balance-windows-2.
(bw-adjust-window): Remove.
(balance-windows-area-adjust): New function with functionality of
bw-adjust-window but using resize-window.
(set-window-text-height): Rewrite doc-string.  Use
normalize-live-window and resize-window.
(enlarge-window-horizontally, shrink-window-horizontally): Rename
argument to DELTA.
(window-buffer-height): New function.
(fit-window-to-buffer, shrink-window-if-larger-than-buffer):
Rewrite using new window resize routines.
(kill-buffer-and-window, mouse-autoselect-window-select): Use
ignore-errors instead of condition-case.
(quit-window): Call delete-frame instead of delete-windows-on
for the only buffer on frame.
lisp/ChangeLog
lisp/window.el
src/ChangeLog
src/window.c